<template>
	<view class="details">
		<view class="details_box">
			<view class="details_box_xia">

			</view>
			<view class="details_box_top">
				<view class="details_box_top_header">
					<view class="details_box_top_header_a">
						<text class="text1">
							购买明细
						</text>
						<text class="text2" style="color: #FF8F1F;">-{{obj.totalMoney}}</text>
					</view>
					<view class="details_box_top_header_b">
						<text class="text1">订单编号{{obj.orderId}}</text>
						<text class="text2">{{obj.orderTime}}</text>
						<!-- <text class="text3">20:30</text> -->
					</view>
				</view>
				<view class="details_box_top_header_c">
					<view class="details_box_mingxi">
						<view class="details_box_a">
							<text class="text1"></text>
							<text class="text2">项目明细</text>
						</view>
						<view class="details_box_b">
							<view class="details_box_yyy">
								<view class="details_box_bottom" v-for="(item,index) in list" :key="item.id">
									<text class="text1">{{item.serviceName}}</text>
									<text class="text2">￥{{item.price}}</text>
								</view>
							</view>
							<view class="details_box_yyy">
								<view class="details_box_bottom">
									<text class="text1">商品总价</text>
									<text class="text2">￥{{obj.realMoney}}</text>
								</view>
							</view>
							<view class="details_box_yyy">
								<view class="details_box_bottom">
									<text class="text1">优惠券金额</text>
									<text class="text2" style="color: #FF8F1F;">-￥{{obj.feeRemission}}</text>
								</view>
							</view>
							<view class="details_box_yyy">
								<view class="details_box_bottom">
									<text class="text1">实际付款</text>
									<text class="text2" style="color: #FF8F1F;">-￥{{obj.totalMoney}}</text>
								</view>
							</view>
							
						</view>
					</view>
				</view>
				<view class="details_box_top_header_c   box">
					<view class="details_box_mingxi">
						<!-- <view class="details_box_a">
							<text class="text1"></text>
							<text class="text2">扣费明细</text>
						</view> -->
						<view class="details_box_b">
							<view class="details_box_yyy">
								<view class="details_box_bottom">
									<text class="text1">订单编号</text>
									<text class="text2">{{obj.orderId}}</text>
								</view>
							</view>
							<view class="details_box_yyy">
								<view class="details_box_bottom">
									<text class="text1">下单时间</text>
									<text class="text2">{{obj.orderTime}}</text>
								</view>
							</view>
							<view class="details_box_yyy">
								<view class="details_box_bottom">
									<text class="text1">付款时间</text>
									<text class="text2">{{obj.payTime}}</text>
								</view>
							</view>
							<view class="details_box_yyy">
								<view class="details_box_bottom">
									<text class="text1">支付方式</text>
									<text class="text2">{{obj.payType}}</text>
								</view>
							</view>
							<!-- <view class="details_box_di">
								<text>合计扣费</text>
								<text>-￥{{obj.decTatolMoney}}</text>
							</view> -->
						</view>
					</view>
				</view>
				<!-- <view class="details_box_top_header_c   box boxs"> -->
					<!-- <view class="details_box_mingxi">
						<view class="details_box_a">
							<text class="text1"></text>
							<text class="text2">车费明细</text>
						</view>
						<view class="details_box_b">


							<view class="details_box_di">
								<text>车费收益</text>
								<text>￥{{obj.travelCost}}</text>
							</view>
						</view>
					</view> -->
				<!-- </view> -->
				<!-- <view class="bottom">
					<text class="text1">实际收益(应得收益-渠道扣费)</text>
					<view class="bottom_right">
						
						<text class="text3">￥{{obj.realReward}}</text>
					</view>
				</view> -->
			</view>
		</view>
	</view>
</template>

<script>
	import homeServices from '../../service/homeService'
	export default {
		data() {
			return {
				list: [],

				detailsid: '',
				obj: {}
			}
		},
		methods: {
			async getdetails() {
				let params = {
					billId: this.detailsid
				}
				let res = await homeServices.getdetails(params)
				// console.log(res.data.serviceItemsList)
				this.list = res.data.serviceItemsList
				
				this.obj = res.data
				console.log(this.list, 'xxxxxxxxxxxxx')
			}
		},
		onShow() {
			this.getdetails()
		},
		onLoad(id) {
			this.detailsid = id.id
			console.log(id.id)
		}
	}
</script>

<style lang="scss" scoped>
	@import '@/static/sass/feededuction.scss'
</style>
